import request from '@/utils/request'

// 获取角色数据
export const roleListService = ({ page, pagesize }) =>
  request.get('/sys/role', { params: { page, pagesize }})

// 新增角色
export const roleAddService = data => request.post('/sys/role', data)

// 修改角色
export const roleUpdateService = data => request.put(`/sys/role/${data.id}`, data)

// 删除角色
export const roleDeleteService = id => request.delete(`/sys/role/${id}`)